package com.lleice.common.entity.resp;

import java.io.Serializable;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

/**
 * 
 * @author lizihao
 *
 */
@Getter
@Setter
@Accessors(chain = true)
@ApiModel("基础响应体")
public class BaseRsp implements Serializable {
    /**
	 * 
	 */
	private static final long serialVersionUID = 4737057182457070608L;
	@ApiModelProperty("响应结果")
    private Result result = Result.ok();

    public static BaseRsp ok() {
        BaseRsp rsp = new BaseRsp();
        rsp.setResult(Result.ok());
        return rsp;
    }
    public static BaseRsp failed() {
        BaseRsp rsp = new BaseRsp();
        rsp.setResult(Result.fail());
        return rsp;
    }
}